﻿//-----------------------------------------------------------------
//
// @(#)$Id: CreateRefundOrder.aspx.cs,v 1.0 2013/12/13 17:54:11 lichunhua Exp $
// @(#)$Author: lichunhua  $
// @(#)$Date: 2013/12/13 17:54:11 $
// @(#)$Description:
//
//
//
//                 All Rights Reserved.
//-----------------------------------------------------------------
using System;
using System.Web.UI.WebControls;
using ebay.Dal.CenterDB_OrderTableAdapters;
using ebay.Dal.K3DataBaseTableAdapters;


public partial class UI_Orders_CreateRefundOrder : System.Web.UI.Page
{
    protected override void OnInit(EventArgs e)
    {
        base.OnInit(e);

        T_RefundTypeTableAdapter rTypeAdapter = new T_RefundTypeTableAdapter();
        ddlType.DataSource = rTypeAdapter.GetData();
        ddlType.DataValueField = "Id";
        ddlType.DataTextField = "RefundType";
        ddlType.DataBind();

        T_DepartMentTableAdapter dAdapter = new T_DepartMentTableAdapter();
        ddlDepartment.DataSource = dAdapter.GetData();
        ddlDepartment.DataValueField = "FitemId";
        ddlDepartment.DataTextField = "FName";
        ddlDepartment.DataBind();

        ddlStatus.Items.Insert(0, new ListItem("未投诉", "0"));
        ddlStatus.Items.Insert(0, new ListItem("已投诉", "1"));
    }

    protected void Page_Load(object sender, EventArgs e)
    {
        if (!IsPostBack)
        {
            string orderId = Request["OrderId"];
            string ebayUserId = Request["EbayUserId"];
            if (!string.IsNullOrEmpty(orderId) && !string.IsNullOrEmpty(ebayUserId))
            {
                txteBayUserId.Value = ebayUserId;
                txtOrderId.Value = orderId;
            }
        }
    }
}